home *** CD-ROM | disk | FTP | other *** search
/ IRIX 6.5 Complementary Applications 2004 February / SGI IRIX 6.5 Complementary Applications 2004 February.iso / dist / OpenOffice.idb / usr / OpenOffice / help / en / sbasic.jar / text / sbasic / common / 03010101.xml < prev    next >
Encoding:
Extensible Markup Language  |  2002-01-24  |  3.1 KB  |  45 lines

  1. <?xml version="1.0" encoding="utf-8"?>
  2. <html><head><title>MsgBox Statement [Runtime]</title><meta name="filename" content="text/sbasic/common/03010101"/><meta name="language" content="en-US"/><help:css-file-link xmlns:help="http://openoffice.org/2000/help"/><!--The CSS style header method for setting styles--><style type="text/css">
  3.  
  4.         p.P1{
  5.                 }
  6.         p.P2{
  7.                 }
  8.         span.T1{
  9.                 font-weight:bold;}
  10.         </style></head><body>
  11.   
  12.   
  13.   <help:to-be-embedded Eid="msgbox" xmlns:help="http://openoffice.org/2000/help">
  14.   <p class="Head1"><help:link Id="66417">MsgBox Statement [Runtime]</help:link><help:key-word value="MsgBox" tag="kw66417_1"/></p>
  15.   <p class="Paragraph">Displays a dialog box containing a message.</p>
  16.   </help:to-be-embedded>
  17.   <p class="Paragraph"><span class="T1">Syntax</span>:</p>
  18.   <p class="Paragraph">MsgBox Text As String [,Type As Integer [,Dialogtitle As String]] (As Statement) or MsgBox (Text As String [,Type As Integer [,Dialogtitle As String]]) (As Function)</p>
  19.   <p class="Paragraph"><span class="T1">Parameter</span>:</p>
  20.   <p class="Paragraph">Text: String expression displayed as a message in the dialog box. Line breaks can be inserted with Chr$(13). Only the first 255 characters of a string are displayed; all exceeding characters are disregarded.</p>
  21.   <p class="Paragraph">DialogTitle: String expression displayed in the title bar of the dialog. If omitted, the title bar displays the name of the respective application.</p>
  22.   <p class="Paragraph">Type: Any integer expression that specifies the dialog type, along with the number and type of buttons to display, and the icon type. <span class="T1">Type</span> represents a combination of bit patterns, i.e., a combination of elements can be defined by adding their respective values:</p>
  23.   <p class="Paragraph">0 : Display OK button only.</p>
  24.   <p class="Paragraph">1 : Display OK and Cancel buttons.</p>
  25.   <p class="Paragraph">2 : Display Cancel and Retry buttons.</p>
  26.   <p class="Paragraph">3 : Display Yes, No and Cancel buttons.</p>
  27.   <p class="Paragraph">4 : Display Yes and No buttons.</p>
  28.   <p class="Paragraph">5 : Display Retry and Cancel buttons.</p>
  29.   <p class="Paragraph">16 : Add the Stop icon to the dialog.</p>
  30.   <p class="Paragraph">32 : Add the Question icon to the dialog.</p>
  31.   <p class="Paragraph">48 : Add the Exclamation icon to the dialog.</p>
  32.   <p class="Paragraph">64 : Add the Information icon to the dialog.</p>
  33.   <p class="Paragraph">0 : First button in the dialog as default button.</p>
  34.   <p class="Paragraph">256 : Second button in the dialog as default button.</p>
  35.   <p class="Paragraph">512 : Third button in the dialog as default button.</p>
  36.   <p class="P2">Example:</p>
  37.   <p class="PropText">Sub ExampleMsgBox</p>
  38.   <p class="PropText">Const sText1 = "An unexpected error occured."</p>
  39.   <p class="PropText">Const sText2 = "The program execution will continue, however."</p>
  40.   <p class="PropText">Const sText3 = "Error"</p>
  41.   <p class="PropText">MsgBox(sText1 + Chr(13) + sText2,16,sText3)</p>
  42.   <p class="PropText">End sub</p>
  43.   <p class="PropText"/>
  44.   <p class="PropText"/>
  45.  </body></html>